package project.configuration.instructions;

import project.layer.physical.Crossroad;
import project.layer.physical.DropOffPoint;
import framework.instructions.creation.CreateInstruction;

public class CreateDropOffPointInstruction extends CreateInstruction{

	private Crossroad crossroad;
	
	
	public CreateDropOffPointInstruction(long executionTime,int objectId,Crossroad crossroad){
		super(executionTime,objectId);
		this.crossroad = crossroad;

	}
	@Override
	protected Object createObject() {
		DropOffPoint dropOffPoint = new DropOffPoint();
		crossroad.setDropOffPoint(dropOffPoint);
		dropOffPoint.setConnector(crossroad);
		return dropOffPoint;
	}

}
